<template>
    <div class="flex h-full">
        <div class="flex-1 pl-3.8rem pt-3.4rem">
            <div class="text-2.8rem">蓝牙控制</div>
            <div class="text-1.8rem mt-4.8rem">蓝牙开关</div>
            <Switch :menus="mode" class=" mt-1.9rem" @change="changeBluetooth"></Switch>
        </div>
        <div class="flex-1 h-full items-center justify-center pt-30rem pl-10rem">
            <SvgIcon class="w-47rem h-43rem" local-icon="setting-car" />
        </div>
    </div>

</template>

<script setup lang="ts">
import Switch from './switch.vue'
import { eventSetting, SettingAction, SettingSwitchEventID, SettingWidget } from '@/hooks/business/eventListen/settingEventListen'

const mode = [
    { "name": "开", "key": "on" },
    { "name": "关", "key": "off" },
];
function changeBluetooth(val: string) {
    eventSetting(SettingAction.Click, SettingWidget.SettingSwitch, SettingSwitchEventID.Bluetooth, val)
}
</script>
